package com.zhu.transaction.service;

import com.zhu.transaction.pojo.BackCategory;
import com.zhu.transaction.pojo.Category;

import java.util.ArrayList;
import java.util.List;

/**
 * <p>
 * 服务类
 * </p>
 *
 * @author zhu
 * @since 2021-01-07
 */
public interface CategoryService {

    //添加分类
    int addCategory(String firstCategory, String[] secondCategory);

    //获取所有分类
    List<BackCategory> getAllCategory();

    //获取某一级分类下的二级分类
    List<BackCategory> getSecondCategory(String parent);

    //通过分类ID获取分类
    Category getCategoryById(String id);

    //删除分类
    int deleteCategory(String ids);

    //更改分类名
    int updateCategory(String id, String categoryName);

}
